#pragma once
#include "Global.h"
#include "Convert.h"

namespace SAVE
{
	enum DIR { RIGHT, RIGHT2DOWN, RIGHTDOWN, RIGHTDOWN2, DOWN, LEFTDOWN2, LEFTDOWN, LEFT2DOWN, LEFT };

	BOOL EyeLV1(IplImage* pOrigin);
	BOOL EyeLeftLV1 ();
	BOOL EyeRightLV1();

	BOOL EyeLV2(IplImage* pOrigin);
	BOOL EyeLeftLV2 ();
	BOOL EyeRightLV2();

	BOOL EyeLV3(IplImage* pOrigin);

	BOOL FaceLV1(IplImage* pOrigin);
	BOOL FaceLV2(IplImage* pOrigin);
	BOOL FaceLV3(IplImage* pOrigin);

	BOOL PencilLV1 (IplImage* pOrigin);
	BOOL PencilLV2 (IplImage* pOrigin);
	BOOL PencilLV3 (IplImage* pOrigin);
	BOOL PencilLV4 (IplImage* pOrigin);
	BOOL PencilLV5 (IplImage* pOrigin);
	BOOL PencilLV6 (IplImage* pOrigin);
	BOOL PencilLV7 (IplImage* pOrigin);
	BOOL PencilLV8 (IplImage* pOrigin);
	BOOL PencilLV9 (IplImage* pOrigin);
	BOOL PencilLV10(IplImage* pOrigin);
	BOOL PencilLV11(IplImage* pOrigin);
	BOOL PencilLV12(IplImage* pOrigin);
	BOOL PencilLV13(IplImage* pOrigin);
	BOOL PencilLV14(IplImage* pOrigin);

	BOOL CharcoalLV1 (IplImage* pOrigin);
	BOOL CharcoalLV2 (IplImage* pOrigin);
	BOOL CharcoalLV3 (IplImage* pOrigin);
	BOOL CharcoalLV4 (IplImage* pOrigin);
	BOOL CharcoalLV5 (IplImage* pOrigin);
	BOOL CharcoalLV6 (IplImage* pOrigin);
	BOOL CharcoalLV7 (IplImage* pOrigin);
	BOOL CharcoalLV8 (IplImage* pOrigin);
	BOOL CharcoalLV9 (IplImage* pOrigin);
	BOOL CharcoalLV10(IplImage* pOrigin);

	void DirPart(IplImage* pImage, CList<Point>* ptList, DIR dir, 
				 UINT* visited, Point start, Point end, int* index, int length = 50);
	void DirLength(IplImage* pImage, CList<Point>* ptList, DIR dir, int length);

	void delEyeLV1();
	void delEyeLV2();
	void delEyeLV3();

	void delFaceLV1();
	void delFaceLV2();
	void delFaceLV3();
	
	void delPencil();
	void delCharcoal();
};